@import "definitions";

@Creator_sidebarWidth: 140px;
@Creator_canvasWidth: 672px;
@Creator_canvasHeight: 480px;
@Creator_vScrollbarWidth: 16px;
@Creator_hScrollbarHeight: @Creator_vScrollbarWidth;
@Creator_canvasLeft: (@Page_width - (2 * @Creator_sidebarWidth) - @Creator_canvasWidth - @Creator_vScrollbarWidth) / 2;
@Creator_tabBarHeight: 30px;
@Creator_tabBar_tabWidth: 80px;
@Creator_separatorHeight: 10px;
@Creator_separatorMargin: 5px;
@Creator_toolbarHeight: 34px;
@Creator_sidebar_statusbarHeight: @Creator_toolbarHeight;

#Creator_main{
	position: relative;
	width: @Page_width;
	height: @Page_height;
	margin: 0 auto;
}

#Creator_left{
	position: absolute;
	width: @Creator_sidebarWidth;
	left: 0;
	top: 0;
	bottom: 0;
}

#Creator_right{
	position: absolute;
	width: @Creator_sidebarWidth;
	right: 0;
	top: 0;
	bottom: 0;
}

#SpritesheetUpload_container{
	position: absolute;
	background-color: #eee;
	width: @Creator_canvasWidth + 16px;
	height: @Page_height - @Creator_tabBarHeight;
	left: @Creator_canvasLeft;
	top: @Creator_tabBarHeight;
	border: 1px solid #ccc;
	background-color: #fff;
}

#SpritesheetUpload_dropText{
	text-align: center;
	margin: 32px;
}

#SpritesheetUpload_container_ovl{
	position: absolute;
	top: 32px;
	bottom: 32px;
	left: 32px;
	right: 32px;
	border: 16px dashed #090;
	display: none;
}

#SpritesheetUpload_canvas{
	width: @Creator_canvasWidth + 14px;
	height: 70px;
}

#SpritesheetUpload_previewCanvas{
	width: 64px;
	height: 64px;
	box-shadow: 0 0 0 1px #ccc;
	margin: 5px;
}

.SpritesheetUpload_section{
	display: inline-block;
	vertical-align: top;
	
	& > * {
		margin: 5px;
	}
}

.SpritesheetUpload_label,
.SpritesheetUpload_input{
	padding: 10px 5px;
	width: 200px;
	text-align: right;
	display: inline-block;
}

.SpritesheetUpload_button{
	padding: 10px 5px;
	border: 1px solid #777;
	width: 200px;
	cursor: pointer;
	display: inline-block;
	
	/*font-size: 16px;
	line-heigth: 16px;*/
	
	&:hover:not(.disabled){
		border-color: #999;
	}
	
	&:first-child i{
		float: right;
	}
	
	i{
		float: left;
		line-height: 22px;
		padding: 0 5px;
	}
	
	p{
		text-align: center;
		line-height: 22px;
	}
	
	&.disabled{
		color: #999;
		cursor: default;
		border-color: #ccc;
	}
}

.Creator_sidebar_separable{
	position: relative;
	margin: 0;
	padding: 0;
	width: @Creator_sidebarWidth;
	height: (@Page_height - @Creator_separatorHeight - 2 * @Creator_separatorMargin) / 2 - @Creator_sidebar_statusbarHeight;
	border: 1px solid #ccc;
	padding: 6px;
	overflow: auto;
}

.Creator_sidebar_statusbar{
	background-color: #ccc;
	width: @Creator_sidebarWidth;
	height: @Creator_sidebar_statusbarHeight;
	
	line-height: @Creator_sidebar_statusbarHeight;
	
	padding: 0 12px;
	
	i {
		&.active{
			color: #55f;
		}
		color: #555;
		line-height: @Creator_sidebar_statusbarHeight;
		cursor: pointer;
		
		&.disabled{
			color: #999;
			cursor: default;
		}
		
		&:not(:first-child){
			margin: 0 0 0 8px;
		}
		&.Creator_sidebar_statusbar_logo{
			float: right;
			color: #fff;
			cursor: default;
			font-size: 24px;
			margin-right: -4px;
		}
	}
	
}

.Creator_sidebar_separator{
	width: @Creator_sidebarWidth;
	height: @Creator_separatorHeight;
	background-color: #ccc;
	cursor:n-resize;
	margin: @Creator_separatorMargin 0;
	border: 4px solid @C_background;
}

#Creator_center{
	position: absolute;
	left: @Creator_sidebarWidth;
	right: @Creator_sidebarWidth;
	top: 0;
	bottom: 0;
}


#Creator_canvas{
	position: absolute;
	background-color: #eee;
	width: @Creator_canvasWidth;
	height: @Creator_canvasHeight;
	left: @Creator_canvasLeft;
	top: @Creator_tabBarHeight;
}

#Creator_tabBar{
	position: absolute;
	width: @Creator_canvasWidth;
	height: @Creator_tabBarHeight;
	overflow: hidden;
	left: @Creator_canvasLeft;
	top: 0;
}

#Creator_tabBar_stop,
#Creator_tabBar_start{
	margin: -@Creator_tabBarHeight 0 0 0;
	width: @Creator_tabBar_tabWidth + 2* @Creator_tabBarHeight;
	height: @Creator_tabBarHeight;
	border-width: @Creator_tabBarHeight;
	border-color: @C_transparent #999 #999 @C_transparent;
	border-style: solid;
	float: right;
	cursor: pointer;
	
	&.disabled{
		color: #777;
		cursor: default;
	}
	
	p{
		i{
			margin-right: 10px;
		}
	
		margin: 0 -@Creator_tabBarHeight 0 0;
		padding: 0 10px;
		text-align: center;
		line-height: @Creator_tabBarHeight;
	}
	
	&:hover:not(.disabled){
		border-color: @C_transparent #eee #eee @C_transparent;
	}
}

#Creator_vScrollbar{
	position: absolute;
	right: @Creator_canvasLeft;
	width: @Creator_vScrollbarWidth;
	height: @Creator_canvasHeight;
	top: @Creator_tabBarHeight;
	border: 7px solid @C_background;
	background-color: #ccc;
	
	.scroller{
		position: absolute;
		top: 0;
		left: -3px;
		width: 8px;
		height: 32px;
		border-radius: 4px;
		background-color: #555;
		display: none;
		cursor: pointer;
	}
}

#Creator_hScrollbar{
	position: absolute;
	left: @Creator_canvasLeft;
	width: @Creator_canvasWidth;
	height: @Creator_hScrollbarHeight;
	top: @Creator_tabBarHeight + @Creator_canvasHeight;
	border: 7px solid @C_background;
	background-color: #ccc;
	
	.scroller{
		position: absolute;
		left: 0;
		top: -3px;
		height: 8px;
		width: 32px;
		border-radius: 4px;
		background-color: #555;
		display: none;
		cursor: pointer;
	}
}

#SpritesheetUpload_canvas_hScrollbar{
	position: relative;
	height: @Creator_hScrollbarHeight;
	width: @Creator_canvasWidth + 14px;
	border: 7px solid @C_background;
	background-color: #ccc;
	
	.scroller{
		position: absolute;
		left: 0;
		top: -3px;
		height: 8px;
		width: 32px;
		border-radius: 4px;
		background-color: #555;
		display: none;
		cursor: pointer;
	}
}

#Creator_toolbar{
	position: absolute;
	height: @Creator_toolbarHeight;
	bottom: 0;
	left: @Creator_canvasLeft;
	right: @Creator_canvasLeft;
	border: 1px solid #ccc;
}

#Creator_toolbar_tools{
	float: right;
	background-color: #ccc;
	height: @Creator_toolbarHeight - 2px;
	line-height: @Creator_toolbarHeight - 2px;
	padding: 0 12px;
	
	i {
	
		&.active{
			color: #77f;
		}
		color: #555;
		line-height: @Creator_toolbarHeight - 2px;
		cursor: pointer;
		&:not(:first-child){
			margin: 0 0 0 8px;
		}
		
		&.bordered{
			border-radius: 5px;
			border: 1px solid #333;
			padding: 2px;
			
			&.active{
				border-color: #77f;
			}
		}
	}
}

.Creator_tabBar_tab{
	margin: 0;
	padding: 0 0 0 @Creator_tabBarHeight;
	width: @Creator_tabBar_tabWidth + 2* @Creator_tabBarHeight;
	height: @Creator_tabBarHeight;
	border-width: @Creator_tabBarHeight;
	border-color: #999 #999 #999 #ccc;
	border-style: solid;
	float: left;
	overflow: visible;
	
	&:not(:last-child):not(.last){
		cursor: pointer;
	}
	
	&:first-child{
		width: @Creator_tabBar_tabWidth + @Creator_tabBarHeight;
		border-color: #999;
		padding: 0;
	}
	
	&:nth-child(2n){
		border-color: #ccc #ccc #ccc #999;
	}
	
	&.last,
	&:last-child{
		width: 0;
		padding: 0;
		border-color: @C_transparent @C_transparent @C_transparent #ccc;
		
		&:nth-child(2n){
			border-color: @C_transparent @C_transparent @C_transparent #999;
		}
	}
	
	&:hover{
		&:first-child{
			border-color: #eee #eee #eee #eee;
		}
		
		&:not(:last-child):not(:first-child):not(.last){
			border-color: #eee #eee #eee #ccc;
			
			&:nth-child(2n){
				border-color: #eee #eee #eee #999;
			}
			
		}
		
		& + .Creator_tabBar_tab{
			border-left-color: #eee;
		}
	}
	
	p{
		i{
			margin-right: 10px;
		}
	
		margin: -@Creator_tabBarHeight;
		padding: 0 0 0 10px;
		line-height: @Creator_tabBarHeight;
	}
}

.Creator_sidebarTile{
	background-color: #999;
	width: 16px;
	height: 16px;
	margin: 1px;
	float: left;
	cursor: pointer;
	
	&:hover{
		box-shadow: 0 0 1px 2px #ccc;
	}
	
	&.active{
		box-shadow: 0 0 1px 1px #fff, 0 0 1px 2px #55c;
	}
	
}

i{
	position: relative;
	
	.hint{
		position: absolute;
		z-index: 5000;
		
		top: -40px;
		display: none;
		
		white-space: nowrap;
		
		span{
			padding: 8px 12px;
			margin-left: -50%;
			background-color: #fff;
			border: 1px solid #ccc;
			color: #555;
			font-family: Nyala, Verdana, Arial, sans-serif;
		}
	}
	
	&.disabled{
		cursor: default !important;
		color: #999 !important;
	}
	
	&:hover:not(.disabled) .hint{
		display: inline;
	}
}


.Creator_left_scenegraph_node{
	background-color: #eee;
	margin-bottom: 5px;
	font-size: 12px;
	padding: 5px 0;
	
	&.active{
		background-color: #cce;
	}
	
	&.clickable p{
		text-decoration: underline;
		cursor: pointer
	}
	
	i{
		font-size: 14px;
		padding: 0 5px;
		margin-right: 5px;
		border-right: 2px solid #fff;
		vertical-align: middle;
		cursor: pointer;
		
		&.semi{
			color: #999;
		}
		
		&.hidden{
			color: #ccc;
		}
	}
	
	p{
		padding: 0px;
		margin: 0px;
		display: inline-block;
		vertical-align: middle;
		
	}
}